package vn.edu.saigontech.ncms.service.impl;

import java.util.Collection;

import org.hibernate.Criteria;
import org.hibernate.criterion.Order;

import vn.edu.saigontech.ncms.model.bookstore.ItemType;
import vn.edu.saigontech.ncms.service.ItemTypeService;

@SuppressWarnings("unchecked")
public class ItemTypeServiceImpl extends HibernateGenericService<ItemType, Long> implements ItemTypeService {
	@Override
	public Collection<ItemType> findAll() {
		Criteria criteria = this.createCriteria();
		criteria.addOrder(Order.asc("order"));
		return criteria.list();
	}
}